﻿using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using DICE_GS;

public class MapButton : MonoBehaviour {
	public UISprite mapButtonImage;
	public UILabel mapName;
	public UISprite SelectedCursor;
	public UILabel[] singleStageNames;
	public string[] singleMapNames;// = new string[5];
	public UISprite[] singleStageSelectedCursors;
	public UILabel[] singleStageNameLabels;

	public GameObject singleStageListObject;

	public bool isShownSigleStageList = false;

	[HideInInspector]
	public int index = 0;

	[HideInInspector]
	public MapListManager manager;
	
	void Awake()
	{
		singleMapNames = new string[5];
	}
	
	
	// Use this for initialization
	void Start () {
		SelectedCursor.gameObject.SetActive(false);
	}
	
	// Update is called once per frame
	void Update () {
	
	}

	void OnClick()
	{
		manager.SelectButton(index);
	}

	public void ShowSingleStages()
	{
		isShownSigleStageList = true;
		TweenScale.Begin(singleStageListObject, 0.3f, Vector3.one);
	}

	public void HideSingleStages()
	{
		isShownSigleStageList = false;
		TweenScale.Begin(singleStageListObject, 0.3f, new Vector3(1f, 0f, 1f));
	}
}
